﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace Front.Controllers
{
    public class ErrorController : Controller
    {
        //
        // GET: /Error/
        public ActionResult Error404()
        {
            SetErrorResponse();
            return View();
        }

        public ActionResult ServerError()
        {
            SetErrorResponse();
            return View();
        }

        private void SetErrorResponse(){
            ViewBag.Url = Request.QueryString["aspxerrorpath"];
     
            Response.StatusCode = 404;
            Response.TrySkipIisCustomErrors = true;
        }
	}
}